CPFLAGS= -g -c -Wall
enterdb : db.o time_util.o string_tokenize.o command_parse.o regex.o
	g++ -o   enterdb db.o time_util.o string_tokenize.o command_parse.o \
		regex.o -ldb_cxx -lpcre
db.o : db.c++ db.hpp
	g++ $(CPFLAGS) db.c++
string_tokenize.o : string_tokenize.c++ string_tokenize.hpp
	g++ $(CPFLAGS) string_tokenize.c++
time_util.o : time_util.c++ time_util.hpp
	g++ $(CPFLAGS) time_util.c++
command_parse.o: command_parse.c++ command_parse.hpp
	g++ $(CPFLAGS) command_parse.c++
regex.o : regex.c++ regex.hpp
	g++ $(CPFLAGS) regex.c++
clean:
	rm enterdb *.o
